﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;

namespace fingerWinForm.Utilities
{
    class CheckInput
    {
        public static bool isNumber(string str)
        {
            bool isNumber = Regex.IsMatch(str, @"^\d+$");
            return isNumber;
        }

        public static bool isLetters(string str)
        {
            bool isLetters = Regex.IsMatch(str, @"^[a-zA-Z]+$");
            return isLetters;
        }

        public static bool isEmpty(string str)
        {
            bool isEmpty = str == "";
            return isEmpty;

        }

        public static bool checkScore(string str)
        {
            bool isOk = str == "0" ||
                        str == "1" ||
                        str == "2" ||
                        str == "3" ||
                        str == "4" ||
                        str == "";
            return isOk;
        }
    }
}
